﻿#region copyright info
//------------------------------------------------------------------------------
// <copyright company="ChaosStudio">
//     Copyright (c) 2002-2010 巧思工作室.  All rights reserved.
//     Contact:		MSN:zhouyu@cszi.com , QQ:478779122
//		Link:				http://www.69sea.com http://www.cszi.com
// </copyright>
//------------------------------------------------------------------------------
#endregion
using System;
using System.Collections.Generic;
using System.Xml.Serialization;
using CS.Util.Text;

namespace CS.WinService
{
    /// <summary>
    ///   任务扩展抽象基类
    /// <example>
    /// <code>
    /// <para>[Serializable]</para>
    /// <para>[XmlRoot("extend")] </para>
    /// <para>public class MyExtend : TaskExtendBase</para>
    /// <para>{...}</para>
    /// </code>
    /// </example>
    /// </summary>
    /// <description class = "CS.WinService.TaskExtendBase">
    ///   请在继承的类加上    [Serializable][XmlRoot("extend")] 
    /// </description>
    /// <history>
    ///   2010-4-19 17:14:12 , zhouyu ,  创建	     
    ///  </history>
    [Serializable]
    [XmlRoot("extend")]
    public abstract class TaskExtendBase
    {
        /// <summary>
        /// 返回扩展的Xml配置文本未例
        /// </summary>
        public virtual string ToXml()
        {
            return Serializer.XmlSerializerToText(this);
        }
    }
}
